package team.first.mongodb.doc;

import cn.edu.nxu.it.movie.entity.Cast;
import cn.edu.nxu.it.movie.entity.Genre;
import cn.edu.nxu.it.movie.entity.Movie;
import dev.morphia.annotations.Entity;
import dev.morphia.annotations.Id;
import lombok.Getter;
import lombok.Setter;
import lombok.ToString;
import lombok.experimental.Accessors;
import org.bson.types.ObjectId;

import java.time.LocalDate;
import java.util.List;

/**
 * @Author: HAPPY
 * @Project_name: project
 * @Package_name: team.first.mongodb.doc
 * @Date: 2021/11/18 23:13
 * @Description：
 */
@Entity(value = "movie", useDiscriminator = false)
@ToString
@Accessors(chain = true)
@Getter
@Setter
public class MovieDoc {
    @Id
    private ObjectId objId;
    private Integer id;
    private String originalTitle;
    private String chineseTitle;
    private String aka;
    private Integer year;
    private LocalDate pubDate;
    private Integer duration;
    private String language;
    private String region;
    private String summary;
    private Double rating;
    private String posterUrl;
    private String poster;
    private List<InnerStaffDoc> directors;
    private List<InnerStaffDoc> actors;
    private List<GenreDoc> genres;
}
